package com.tsmti.doctor.entity;

import com.tsmti.core.common.entity.BaseDataEntity;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;
import org.hibernate.annotations.Where;

import javax.persistence.*;

/**
 * @Package：com.tsmti.doctor.entity
 * @Class：PimsReqPack
 * @Description： TODO
 * @Author：king
 * @Date：Created in 2018/11/12 16:35
 * @Company:
 * @Version：
 * @Modified By:
 */
@Entity
@Table(name = "PIMS_REQ_PACK")
@DynamicInsert
@DynamicUpdate
@Where(clause = "delFlag = 0")
public class PimsReqPack extends BaseDataEntity<Long> {
    /**
     *主键
     */
    private Long id;
    /**
     * 打包号
     */
    private String packno;
    /**
     * 申请单id
     */
    private Long reqId;

    @Id
    @Column(name = "ID")
    @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "SEQ_REQ_PACK")
    @SequenceGenerator(name = "SEQ_REQ_PACK", sequenceName = "SEQ_REQ_PACK", allocationSize = 1)
    @Override
    public Long getId() {
        return id;
    }
    @Override
    public void setId(Long id) {
        this.id = id;
    }

    @Basic
    @Column(name = "PACKNO")
    public String getPackno() {
        return packno;
    }

    public void setPackno(String packno) {
        this.packno = packno;
    }

    @Basic
    @Column(name = "REQID")
    public Long getReqId() {
        return reqId;
    }

    public void setReqId(Long reqId) {
        this.reqId = reqId;
    }
}
